package cc.iotkit.data.service;

import cc.iotkit.data.manager.IIotContributorData;
import cc.iotkit.data.mapper.IJPACommData;
import cc.iotkit.data.model.TbIotContributor;
import cc.iotkit.model.contribution.IotContributor;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @Author: 石恒
 * @Date: 2023/8/3 22:26
 * @Description:
 */
@Primary
@Service
public class IotContributorDataImpl implements IIotContributorData, IJPACommData<IotContributor, Long, TbIotContributor> {

    @Resource
    @Qualifier("DBIotContributorServiceImpl")
    private IotContributorService iotContributorService;

    @Override
    public IotContributorService getBaseRepository() {
        return iotContributorService;
    }

    @Override
    public Class getJpaRepositoryClass() {
        return TbIotContributor.class;
    }

    @Override
    public Class getTClass() {
        return IotContributor.class;
    }
}
